package com.zhaowb.springcloud.admin.biz;

import com.zhaowb.springcloud.admin.entity.Element;
import com.zhaowb.springcloud.admin.mapper.ElementMapper;
import com.zhaowb.springcloud.common.biz.BaseBiz;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * Created with IDEA
 *
 * @author zhaowb
 * @date 2018/11/7 15:09
 */
@Service
public class ElementBiz extends BaseBiz<ElementMapper, Element> {

    public List<Element> getAuthorityElementByUserId(String userId) {
        return mapper.selectAuthorityElementByUserId(userId);
    }

    public List<Element> getAuthorityElementByUserId(String userId, String menuId) {
        return mapper.selectAuthorityMenuElementByUserId(userId, menuId);
    }
}
